Add canvas zoom and Spacebar pan (SP-024) - #40
Merged
Conversation
- Ship viewport camera in react-canvas-designer@1.2.0 (wheel zoom, Space+drag pan) - Keep sticker pinch aligned under zoom/pan; expose getViewport/zoomBy/resetViewport - Demo Zoom −/%/+/Reset on docs /stickpak; update phase-1 and engineering notes Co-authored-by: Cursor <cursoragent@cursor.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements StickPak Kanban SP-024: Figma-style canvas zoom and Spacebar+drag pan inside
@jeffgo10/react-canvas-designer1.2.0, with a docs/stickpakdemo. Viewport is runtime UI only (not layout JSON).Changes
Packages (
@jeffgo10/*)react-canvas-designer1.1.1 → 1.2.0canvasViewport.ts(clamp zoom 1…4, pan clamp, zoom-toward-point, Stage transform compose)x/yinside overflow-hidden shellgetViewport/setViewportZoom/zoomBy/resetViewport;onViewportChangepropstagePointerToDesignand pinchtouchClientToDesignso SP-006 sticker pinch stays aligned when zoomed/pannedDocs app (
apps/docs)/stickpakZoom − / % / + / Reset view toolbar + help textDocs / Cursor rules / agent tooling
docs/stickpak/phase-1.md,engineering-notes.md, package README,ls-foundry-core.mdcpinCommits
bf26481Test plan
pnpm test --filter=@jeffgo10/react-canvas-designerpnpm run build:packages(orpnpm run build)pnpm run dev --filter=@ls-foundry/docs→/stickpakNotes / follow-ups
pnpm run deploy/ CI publish for@jeffgo10/react-canvas-designer@1.2.0use-canvas-viewport(prefer designer camera or keep outer CSS viewport for mobile only)Made with Cursor